package com.lekang.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.lekang.mapper.LeaveApprovalRecordMapper;
import com.lekang.domain.LeaveApprovalRecord;
import com.lekang.service.ILeaveApprovalRecordService;

/**
 * 请假审批记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-10-14
 */
@Service
public class LeaveApprovalRecordServiceImpl implements ILeaveApprovalRecordService 
{
    @Autowired
    private LeaveApprovalRecordMapper leaveApprovalRecordMapper;

    /**
     * 查询请假审批记录
     * 
     * @param id 请假审批记录主键
     * @return 请假审批记录
     */
    @Override
    public LeaveApprovalRecord selectLeaveApprovalRecordById(Long id)
    {
        return leaveApprovalRecordMapper.selectLeaveApprovalRecordById(id);
    }

    /**
     * 查询请假审批记录列表
     * 
     * @param leaveApprovalRecord 请假审批记录
     * @return 请假审批记录
     */
    @Override
    public List<LeaveApprovalRecord> selectLeaveApprovalRecordList(LeaveApprovalRecord leaveApprovalRecord)
    {
        return leaveApprovalRecordMapper.selectLeaveApprovalRecordList(leaveApprovalRecord);
    }

    /**
     * 新增请假审批记录
     * 
     * @param leaveApprovalRecord 请假审批记录
     * @return 结果
     */
    @Override
    public int insertLeaveApprovalRecord(LeaveApprovalRecord leaveApprovalRecord)
    {
        return leaveApprovalRecordMapper.insertLeaveApprovalRecord(leaveApprovalRecord);
    }

    /**
     * 修改请假审批记录
     * 
     * @param leaveApprovalRecord 请假审批记录
     * @return 结果
     */
    @Override
    public int updateLeaveApprovalRecord(LeaveApprovalRecord leaveApprovalRecord)
    {
        return leaveApprovalRecordMapper.updateLeaveApprovalRecord(leaveApprovalRecord);
    }

    /**
     * 批量删除请假审批记录
     * 
     * @param ids 需要删除的请假审批记录主键
     * @return 结果
     */
    @Override
    public int deleteLeaveApprovalRecordByIds(Long[] ids)
    {
        return leaveApprovalRecordMapper.deleteLeaveApprovalRecordByIds(ids);
    }

    /**
     * 删除请假审批记录信息
     * 
     * @param id 请假审批记录主键
     * @return 结果
     */
    @Override
    public int deleteLeaveApprovalRecordById(Long id)
    {
        return leaveApprovalRecordMapper.deleteLeaveApprovalRecordById(id);
    }
}
